<template>
    <div>
        home.vue
        <button v-role="'admin'" @click="test">测试</button>
    </div>
</template>

<script setup>
import { get } from '@/utils/request'
import router from '@/router'

async function test() {

    const res = get('/getRoute')

    console.info(router.getRoutes())
}

</script>

<style lang="less" scoped></style>